import { getStoreList } from './ecommerce/storeManage';
import request from '@/utils/request'

//标签规则列表
export function ruleList(data: any) {
  return request({
    url: '/scrm-api/console/tag/rule/list',
    method: 'POST',
    data: data
  })
}

//修改状态接口
export function ruleStatus(data: any) {
  return request({
    url: '/scrm-api/console/tag/rule/status',
    method: 'GET',
    params: data
  })
}

//删除规则标签接口
export function delRule(data: any) {
  return request({
    url: '/scrm-api/console/tag/rule/del',
    method: 'GET',
    params: data
  })
}

//标签规则详细数据
export function ruleDetaile(data: any) {
  return request({
    url: '/scrm-api/console/tag/rule/detaile',
    method: 'POST',
    data: data
  })
}

//客户来源列表
export function customerSource(data: any) {
  return request({
    url: '/scrm-api/console/customer/source/list',
    method: 'POST',
    data: data
  })
}

//客户标签规则创建
export function createRule(data: any) {
  return request({
    url: '/scrm-api/console/tag/rule/create',
    method: 'POST',
    data: data
  })
}

//客户标签筛选有多少客户
export function ruleScreen(data: any) {
  return request({
    url: '/scrm-api/console/tag/rule/screen',
    method: 'POST',
    data: data
  })
}

//标签规则详情接口
export function ruleInfo(data: any) {
  return request({
    url: '/scrm-api/console/tag/rule/info',
    method: 'GET',
    params: data
  })
}

//编辑打标签
export function ruleUpdate(data: any) {
  return request({
    url: '/scrm-api/console/tag/rule/update',
    method: 'POST',
    data: data
  })
}

//是否开启会话存档
export function ruleArchived() {
  return request({
    url: '/scrm-api/console/tag/rule/archived',
    method: 'POST'
  })
}

//店铺类型
export function getCommonhop(data: any) {
  return request({
    url: '/weiwork/client/common/dict_enum',
    method: 'GET',
    params: data
  })
}

//店铺列表
export function getStoreList(data: any) {
  return request({
    url: '/scrm-api/console/tag/rule/store-list',
    method: 'POST',
    data: data
  })
}

//获取店铺页面列表
export function pageList(data: any) {
  return request({
    url: '/scrm-api/console/media/content/page/all/list',
    method: 'GET',
    params: data
  })
}
